const routes = [
  {
    path: '/mainlayout',
    name: 'MainLayout',
    component: () => import('../views/MainLayout.vue'),
    redirect: '/mainlayout/blogindex',
    children: [
      {
        path: 'blogindex',
        name: 'BlogIndex',
        component: () => import('../views/blog/BlogIndex.vue'),
      },
      {
        path: 'mineindex',
        name: 'MineIndex',
        component: () => import('../views/mine/MineIndex.vue'),
      },
      // 文章详情
      {
        path: 'blogdetail/:id',
        name: 'BlogDetail',
        component: () => import('../views/blog/BlogDetail.vue'),
      },
      // 搜索结果
      {
        path: 'searchresult',
        name: 'SearchResult',
        component: () => import('../views/blog/SearchResult.vue'),
      },
    ],
  },
]

export default routes
